<template>
  <div>我是一个测试页面</div>VNode
  <pug-test :text="pname"></pug-test>VNode
  <pug-test :text="cname" :key="timer"></pug-test>
  <button @click="getCity">获取城市</button>
  <pug-map id="1" @select="getMapData"></pug-map>
  <div>{{result}}</div>
</template>

<script>
import PugMap from "@/components/map/PugMap";
export default {
  name: "test.vue",
  components: {PugMap},
  data(){
    return {
      pname:"湖南省",
      timer:null,
      cname:"",
      result:{}
    }
  },
  methods:{
    getCity(){
      this.timer = new Date().getTime();
      this.cname = "长沙市"
    },

    getMapData(data){
      this.result = data.point;
    }
  }
}
</script>

<style scoped>

</style>
